import CodoBase from "../../lib/CodoBase";

import * as hkvs from "../../lib/hikvision/isc";
import { hikvision } from "../../lib/hikvision/isc/type";

export default class HikvisionISC extends CodoBase {
	/** 直接提供总的海康服务类 */
	hkvs = hkvs;

	getAuthServiceInstance(config: hikvision.isc.ISCConfig) {
		return new hkvs.AuthService(this.app, config);
	}

	getEventServiceInstance(config: hikvision.isc.ISCConfig) {
		return new hkvs.EventService(this.app, config);
	}

	getOrgServiceInstance(config: hikvision.isc.ISCConfig) {
		return new hkvs.ResourceOrgService(this.app, config);
	}

	getPersonServiceInstance(config: hikvision.isc.ISCConfig) {
		return new hkvs.ResourcePersonService(this.app, config);
	}

	getAcsDoorServiceInstance(config: hikvision.isc.ISCConfig) {
		return new hkvs.AcsDoorService(this.app, config);
	}

	getConsumeCemsServiceInstance(config: hikvision.isc.ISCConfig) {
		return new hkvs.ConsumeCemsService(this.app, config);
	}
	getVehicleServiceInstance(config: hikvision.isc.ISCConfig) {
		return new hkvs.ResourceVehicleService(this.app, config);
	}
}
